package models

type DeviceInfo_Concentrator_User struct {
	ID                         int64               `gorm:"not null;column:ID; PRIMARY_KEY"`
	Device_ID                  int64               `gorm:"not null;column:Device_ID"`                  //deviceinfo表id
	DeviceInfo_Concentrator_ID int64               `gorm:"not null;column:DeviceInfo_Concentrator_ID"` //DeviceInfo_Concentrator表id
	Name                       string              `gorm:"not null;column:Name"`
	Describe                   *string             `gorm:"column:Describe"`
	Mn                         string              `gorm:"not null;column:Mn"` //用户表地址
	DeviceInfo_Detail          []DeviceInfo_Detail `gorm:"foreignKey:DeviceInfo_Concentrator_User_ID;references:ID;constraint:OnDelete:CASCADE"`
}

// 配置数据库操作的表名称
func (DeviceInfo_Concentrator_User) TableName() string {
	return "DeviceInfo_Concentrator_user"
}

type EditDeviceInfo_Concentrator_UserRequest struct {
	DeviceInfo_Concentrator_User DeviceInfo_Concentrator_User `json:"DeviceInfo_Concentrator_User"`
}
